package com.smgeek.gkrpc.codec;

import com.alibaba.fastjson.JSON;

/**
 * @ClassName JSONEncoder
 * @Author wuyuyang
 * @Date 2022/1/6 14:57
 * @Description JSONEncoder 基于Json的序列化
 * @Version 1.0
 */
public class JSONEncoder implements Encoder{
    @Override
    public byte[] encode(Object obj) {

        return JSON.toJSONBytes(obj);
    }
}
